<html>
<head>
    <title>Title</title>
    <link rel="stylesheet" href="/resources/lib/layui-v2.6.3/css/layui.css"
          media="all">
    <script src="/resources/lib/layui-v2.6.3/layui.js" charset="utf-8"></script>
</head>
<body>
<div class="layui-card" style="margin-left: 10px;margin-right: 10px;padding-bottom: 20px">
<form class="layui-form" id="dataFrm" lay-filter="dataFrm" action="" style="padding-top: 10px">
    <div class="layui-form-item layui-col-lg5">
        <label class="layui-form-label ">头像</label>
        <div class="layui-input-block" >
            <div class="layui-upload-list" style="margin-left: 12px;margin-top: 12px">
                <img src="/user/imgDownload.do" id="headImgView" style="width: 100px;height: 100px">
            </div>
        </div>
    </div>
    <div class="layui-form-item layui-col-lg5">
        <label class="layui-form-label">用户名</label>
        <div class="layui-input-block">
            <input type="text" name="username"  lay-verify="title" autocomplete="off" class="layui-input">
        </div>
    </div>

    <div class="layui-form-item">
        <div class="layui-inline">
            <label class="layui-form-label">ID</label>
            <div class="layui-input-inline">
                <input type="text" name="id" readonly lay-verify="required" autocomplete="off" class="layui-input">
            </div>
        </div>
        <div class="layui-inline">
            <label class="layui-form-label">真实姓名</label>
            <div class="layui-input-inline">
                <input type="text" name="realname" lay-verify="required" autocomplete="off" class="layui-input">
            </div>
        </div>
    </div>
    <div class="layui-form-item">
        <div class="layui-inline">
            <label class="layui-form-label">注册时间</label>
            <div class="layui-input-inline">
                <input type="text" name="createTime" readonly  autocomplete="off" class="layui-input">
            </div>
        </div>
        <div class="layui-inline">
            <label class="layui-form-label">更新时间</label>
            <div class="layui-input-inline">
                <input type="text" name="updateTime" readonly id="date"  autocomplete="off" class="layui-input">
            </div>
        </div>
        <div class="layui-inline">
            <label class="layui-form-label">注销时间</label>
            <div class="layui-input-inline">
                <input type="tel" name="deletedTime"  readonly autocomplete="off" class="layui-input">
            </div>
        </div>
    </div>
    <div class="layui-form-item">
        <div class="layui-input-block">
            <button type="button" id="doSubmit" class="layui-btn" lay-submit  lay-filter="doSubmit">立即提交</button>
            <button type="reset" class="layui-btn layui-btn-primary">重置</button>
        </div>
    </div>
</form>
</div>
<script type="text/javascript">
    layui.use(['layer', 'jquery', 'form'], function () {
        let layer = layui.layer;
        let $ = layui.jquery;
        let form = layui.form;
        $.get("/user/queryCurrentUser.do",function (res) {
            console.log(res.data)
            form.val("dataFrm",res.data)
        })

        form.on("submit(doSubmit)",function (obj) {
            console.log(obj)
        })
    })
</script>
</body>
</html>
